package com.farm.decorator;

import com.farm.equipment.Equipment;
import com.farm.equipment.EquipmentState;

public class GPSDecorator extends EquipmentDecorator {
    public GPSDecorator(Equipment equipment) {
        super(equipment);
    }

    @Override
    public void work() {
        System.out.println("GPS定位系统启动");
        System.out.println("实时追踪设备位置");
        super.work();
    }

    @Override
    public void stop() {
        System.out.println("GPS定位系统关闭");
        super.stop();
    }

    public void updateLocation() {
        System.out.println("更新GPS位置信息");
        setLocation("经度: 116.404, 纬度: 39.915");
    }
} 